package com.wenzhi.java_join_kotlin.service.impl

import org.junit.jupiter.api.AfterEach
import org.junit.jupiter.api.BeforeEach
import org.junit.jupiter.api.Test

import org.junit.jupiter.api.Assertions

class MinCostTicketsServiceImplTest {

    @BeforeEach
    fun setUp() {
    }

    @AfterEach
    fun tearDown() {
    }

    @Test
    fun minCostTickets() {
        // days = [1,4,6,7,8,20], costs = [2,7,15]
        // expected = 11
        val days = intArrayOf(1, 4, 6, 7, 8, 20)
        val costs = intArrayOf(2, 7, 15)
        val expected = 11
        val actual = MinCostTicketsServiceImpl().minCostTickets(days, costs)
        println("actual: ${actual}")
        Assertions.assertEquals(expected, actual)
    }
}